function CheckFieldString(type, formField, strMsg) 
{
	var checkOK;
	var checkStr = formField.value;
	var allValid = true;
	var flagDot  = false;
	var namestr, domainstr;
	
	if (type == 'noblank')
	{
		if (checkStr == "")
		{
			return (strMsg  + String.fromCharCode(10));
		}
	} 
	else 	
	{
		if (type == 'integer')	
		{
			checkOK = "0123456789";
		} 
		else if (type == 'decimal')
		{	
			checkOK = "0123456789.";
		} 
		else if (type == 'text') 
		{
			checkOK = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ";
		} 
		else if (type == 'alphanumeric') 
		{
			checkOK = "0123456789.+-_#,/ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ()_";
		} 
		else if (type == 'full') 
		{
			checkOK = "0123456789.,[]{}=+-_#,/ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ()_:;'\\*^%$@<>?'";
		} 
		else if (type == 'alphanum') 
		{
			checkOK = "0123456789_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ";
		} 
		else if (type == 'verificationcode') 
		{
			checkOK = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
		} 
		else if (type == 'email')
		{
			checkOK = "0123456789_-@.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
			if ( /^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,7})+$/.test(checkStr) )
			{
			}
			else
			{
				return (strMsg  + String.fromCharCode(10));
			}
		} 
		else if (type == 'phone') 
		{
			checkOK = "0123456789-+";
		} 
		else if (type == 'URL') 
		{
			checkOK = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.:/\\";
		} 
		else if (type == 'path') 
		{
			checkOK = "0123456789.+-_#,/ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz () \\ ";
		} 
		else 
		{
			return "Check Validation one of the mentioned validation type is wrong" + String.fromCharCode(10);
		}
		
		for (i = 0;  i < checkStr.length;  i++)
		{
			ch = checkStr.charAt(i);
			for (j = 0;  j < checkOK.length;  j++) 
			{
				if (ch == checkOK.charAt(j)) 
				{
					break; 
				}
				if (j == checkOK.length-1)
				{	
					allValid = false;
					break;
				}
			}
				
			if (!allValid)
			{
				return (strMsg  + String.fromCharCode(10));
			}
		}
		
		if (type == 'decimal') /* for decimal type */
		{
			for (t = 0;  t < checkStr.length;  t++)
			{	
				dot = checkStr.charAt(t);
				if (dot == '.' && flagDot == false) 
				{
					flagDot = true;
				} 
				else if (dot =='.' && flagDot == true)
				{
					return (strMsg + String.fromCharCode(10));
				}
			}
		}
	}
	return "";
}